﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="jqueryDialogDemo.aspx.cs"
    Inherits="WebApplication1.jqueryDialogDemo" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <script src="jquery-1.7.2.js" type="text/javascript"></script>
    <script src="jquery.bgiframe-2.1.2.js" type="text/javascript"></script>
    <script src="jquery.ui.core.js" type="text/javascript"></script>
    <script src="jquery.ui.widget.js" type="text/javascript"></script>
    <script src="jquery.ui.dialog.js" type="text/javascript"></script>
    <script src="jquery.ui.mouse.js" type="text/javascript"></script>
    <script src="jquery.ui.draggable.js" type="text/javascript"></script>
    <script src="jquery.ui.position.js" type="text/javascript"></script>
    <script src="jquery.ui.resizable.js" type="text/javascript"></script>
    <script src="jquery.effects.core.js" type="text/javascript"></script>
    <script src="jquery.effects.blind.js" type="text/javascript"></script>
    <script src="jquery.effects.explode.js" type="text/javascript"></script>
 
    <script type="text/javascript">
        $(function () {
            $("#btnAdd").click(function () {
                $('#btnAdd').dialog({
                    Width: "500",
                    Height: "500",
                    Title: "模式对话框",
                    skin: "blue",
                    FrameURL: "WebForm2.aspx",
                    ContentFlag: "0"
                })
            });


            $('table a').each(function () {
                var val = $(this).attr("accesskey");
                $(this).dialog({
                    Width: "500",
                    Height: "500",
                    Title: "模式对话框",
                    skin: "blue",
                    FrameURL: "WebForm2.aspx?ID=" + val,
                    ContentFlag: "0"
                });
            });
        })
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="false">
            <Columns>
                <asp:TemplateField HeaderText="修改">
                    <ItemTemplate>
                        <a href="#" accesskey='<%#Eval("TypeID") %>'>修改4</a>
                        <input id="btnShow" type="button" value="修改3" runat="server" />
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
        </asp:GridView>
        <asp:Button ID="Button1" runat="server" Text="Button" />
        <input type="button" value="新增" id="btnAdd" />
    </div>
    </form>
</body>
</html>
